package com.cleaningcloud.erp.domain;

import java.math.BigDecimal;
import java.util.Date;

import com.cleaningcloud.common.core.web.domain.BaseEntity;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import lombok.EqualsAndHashCode;
import com.cleaningcloud.common.core.annotation.Excel;

/**
 * 应付账款对象 erp_accounts_payable
 * 
 * @author cleaningcloud
 * @date 2024-09-30
 */
@EqualsAndHashCode(callSuper = true)
@Data
public class ErpAccountsPayable extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 应付账款ID */
    private Long payableId;

    /** 单据编号 */
    @Excel(name = "单据编号", sort = 3)
    private String oddNo;

    /** 单据类型(1采购单2销售退货单) */
    @Excel(name = "单据类型", sort = 2, readConverterExp = "1=采购单,2=销售退货单,3=采购退换")
    private Integer oddType;

    /** 客户/供应商ID */
    private Long businessId;

    /** 单据日期 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "单据日期", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss", sort = 1)
    private Date oddDate;

    /** 单据状态(0未收款1已收款) */
    @Excel(name = "单据状态", sort = 8, readConverterExp = "0=未收款,1=已收款")
    private Integer oddStatus;

    /** 应付金额 */
    @Excel(name = "金额", sort = 9)
    private BigDecimal oddSumMoney;

    /** 实付金额 */
    @Excel(name = "付款金额", sort = 10)
    private BigDecimal oddMoney;

    /** 付款人ID */
    private Long userId;

    /** 付款人名称 */
    private String userName;

    /** 付款时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "付款时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss", sort = 11)
    private Date payTime;

    /** 备用是否关闭 */
    private String flag;

    // 批量导出Ids
    private String exportIds;
}
